<div class="wrapper wrapper-content">
    <div class="row">
        <div class="col-lg-12">
            <div class="tabs-container">
                <uib-tabset>
                    <uib-tab heading="{{'USER.API_KEY_LIST' | translate}}">
                        <div class="panel-body" ng-controller="ApiKeyController">
                            <a ng-click="addApiKey()" class="btn btn-primary btn-rounded btn-outline" href=""><i
                                    class="fa fa-plus-circle"></i> {{'USER.ADD_API_KEY' | translate}}</a>
                            <br>
                            <br>
                            <table class="footable table table-bordered table-hover" data-sort="true" data-page-size="15">
                                <thead>
                                    <tr>
                                        <th class="text-center" data-type="numeric">{{'SETTING.ID' | translate}}</th>
                                        <th class="text-center">{{'SETTING.NAME' | translate}}</th>
                                        <th class="text-center">{{'GATEWAY.TOKEN' | translate}}</th>
                                        <th class="text-center">{{'SETTING.CREATED_TIME' | translate}}</th>
                                        <th class="text-center">{{'SETTING.EXPIRES_TIME' | translate}}</th>
                                        <th class="text-center">{{'SETTING.ACTION' | translate}}</th>
                                    </tr>
                                </thead>
                                <tbody>
                                    <tr ng-repeat="apiKey in apiKeys">
                                        <td class="text-center">{{ apiKey.id }}</td>
                                        <td class="text-center">{{ apiKey.name }}</td>
                                        <td class="text-center" style="max-width: 400px; word-wrap: break-word;">
                                            {{ apiKey.token }}
                                            <button class="btn btn-primary btn-rounded btn-xs" ng-click="copyToClipboard(apiKey)">{{'SETTING.COPY' | translate}}</button>
                                        </td>
                                        <td class="text-center">{{ apiKey.created_datetime }}</td>
                                        <td class="text-center">{{ apiKey.expires_datetime }}</td>
                                        <td class="text-center">
                                            <a class="btn btn-primary btn-rounded btn-xs" ng-click="editApiKey(apiKey)">{{'SETTING.EDIT' | translate}}</a>
                                            <a ng-click="deleteApiKey(apiKey)" class="btn btn-danger btn-rounded btn-xs">{{'SETTING.DELETE' | translate}}</a>
                                        </td>
                                    </tr>
                                </tbody>
                                <tfoot class="hide-if-no-paging">
                                    <tr>
                                        <td colspan="6">
                                            <ul class="pagination pull-right"></ul>
                                        </td>
                                    </tr>
                                </tfoot>
                            </table>
                        </div>
                    </uib-tab>
                </uib-tabset>

            </div>
        </div>
    </div>



</div>